package com.bbb.blogservice;

import java.io.File;

public class Main {

    public static void main(String[] args) {
	    //获取文件夹下所有文件
        File folder = new File(args[0]);
        File[] files = folder.listFiles();
        Integer remainder = files.length % 8;
        Integer rounded = files.length / 8;
        Integer runCount = remainder + (rounded > 0 ? 1 : 0);
        Calculate calculate = new Calculate(files);
        for (int i = 0; i < 3; i ++) {
            Thread thread = new Thread(calculate);
            thread.start();
        }


    }
}
